<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
 "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml"
	xmlns:h="http://java.sun.com/jsf/html"
	xmlns:f="http://java.sun.com/jsf/core"
	xmlns:p="http://primefaces.prime.com.tr/ui">
<h:head>
	<title>#{msgs.loginTitle}</title>
</h:head>
<h:body>
	<h:form>
		<p:panel header="Вход в систему" style="width:310px">
			<p:messages showDetails="true" id="messages" />
			<h:panelGrid columns="2" cellpadding="5">
				<h:outputLabel for="username" value="Имя пользователя" />
				<p:inputText id="j_username" required="true" label="username"					
					requiredMessage="Поле 'Имя пользователя' обязательно для заполнения.">
					<f:validateLength minimum="4" />
				</p:inputText>
				<h:outputLabel value="Пароль" />
				<p:password feedback="false" id="j_password">
					<f:validateLength minimum="4" />
				</p:password>
				<label for="_spring_security_remember_me"> 
					<h:outputText value="Remember me" /> 
				</label>
				<h:selectBooleanCheckbox id="_spring_security_remember_me" />

				<p:commandButton value="Ввойти" update="messages" actionListener="#{loginController.doLogin}" ajax="false" />
			</h:panelGrid>
		</p:panel>
	</h:form>
</h:body>
</html>